<?php

namespace app\model;

use think\Model;
use think\model\concern\SoftDelete;

class BaseModel extends Model
{
    public $error = ''; //异常信息

    // 定义时间戳字段名
    protected $createTime = 'create_time';
    protected $updateTime = 'update_time';



    /**
     * 开启时间戳自动写入
     *
     * @var boolean
     * @Author YangHB
     * @DateTime 2022-07-12 13:17:11
     *
     */
    protected $autoWriteTimestamp = true;


    /**
     * Notes: 获取异常信息抛出
     * User: chenLei
     * Date: 9/7/25
     * @return mixed|string
     */
    public function getError()
    {
        return $this->error;
    }
}